//
//  TagHistory+CoreDataClass.swift
//  Drop
//
//  Created by hushaohua on 2017/12/19.
//  Copyright © 2017年 init. All rights reserved.
//
//

import Foundation
import CoreData

@objc(TagHistory)
public class TagHistory: NSManagedObject {
    var context:NSManagedObjectContext?;
    static func newInstance() -> TagHistory{
        let context : NSManagedObjectContext = HStoreManager.defaultManger().context;
        let history:TagHistory = NSEntityDescription.insertNewObject(forEntityName: "TagHistory", into: context) as! TagHistory;
        return history;
    }
    
    static func defaultSort() -> NSSortDescriptor{
        return NSSortDescriptor(key: "created", ascending: false);
    }
}
